PATH![]() |
![]() ![]() |
Assigns a relative weight to a task, indicating how much processor time it should receive compared to other available tasks.
OSStatus MPSetTaskWeight (
MPTaskID task,
MPTaskWeight weight);
The approximate processor share is defined as
weight of the task/ total weight of available tasks
For a set of ready tasks, the amount of CPU time dedicated to the tasks will be determined by the dynamically computed share. Note that the processor share devoted to tasks may deviate from the suggested weighting if critical tasks require attention. For example, a real-time task (such as a QuickTime movie) may require more than its relative weight of processor time, and the scheduler will adjust proportions accordingly.